package cn.hl.hm.entity;

import java.io.Serializable;
import java.util.Date;

import org.springframework.format.annotation.DateTimeFormat;

import com.vizhuo.base.model.BaseModel;
import com.vizhuo.utils.DateUtil;
import com.vizhuo.utils.term.TermManager;
import com.vizhuo.utils.term.Terms;

/**
 * 会员-账号
 * 
 * @author luzh
 * @version 1.0
 */
public class MebAccVO extends BaseModel<java.lang.Integer> implements Serializable {

    private String account;

    private String pwd;

    private String accountType;

    private String statusFlag;// 账户状态（黑名单，正常）

    @DateTimeFormat(pattern = "yyyy-MM-dd")
    private Date regDatetime;

    // extend
    private String infoName;// 信息部公司名字

    private String consignerName;// 商户姓名

    /* 以下4个字段是冗余meb_info表中的 */
    private String name;// 真实姓名,冗余meb_info中的字段

    private String checkFlag;// 审核状态

    private java.math.BigDecimal highPraiseRate;// 好评率

    private String checkFlagRemark;// 审核失败理由

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getCheckFlag() {
        return checkFlag;
    }

    public void setCheckFlag(String checkFlag) {
        this.checkFlag = checkFlag;
    }

    public java.math.BigDecimal getHighPraiseRate() {
        return highPraiseRate;
    }

    public void setHighPraiseRate(java.math.BigDecimal highPraiseRate) {
        this.highPraiseRate = highPraiseRate;
    }

    public String getAccount() {
        return account;
    }

    public void setAccount(String account) {
        this.account = account;
    }

    public String getPwd() {
        return pwd;
    }

    public void setPwd(String pwd) {
        this.pwd = pwd;
    }

    public String getAccountType() {
        return accountType;
    }

    public void setAccountType(String accountType) {
        this.accountType = accountType;
    }

    public String getStatusFlag() {
        return statusFlag;
    }

    public void setStatusFlag(String statusFlag) {
        this.statusFlag = statusFlag;
    }

    public String getStatusFlagLabel() {
        return TermManager.getlabel4Value(Terms.mebAccStatusFlagList(), statusFlag);
    }

    public String getAccountTypeLabel() {
        return TermManager.getlabel4Value(Terms.mebAccTypeFlagList(), accountType);
    }

    public Date getRegDatetime() {
        return regDatetime;
    }

    public void setRegDatetime(Date regDatetime) {
        this.regDatetime = regDatetime;
    }

    public String getRegDatetimeStr() {
        return DateUtil.date2String(regDatetime);
    }

    public String getRegDatetimeYYYYMMDDStr() {
        return DateUtil.date2String(regDatetime);
        // return DateUtil.date2StringNoTime(regDatetime);
    }

    public String getInfoName() {
        return infoName;
    }

    public void setInfoName(String infoName) {
        this.infoName = infoName;
    }

    public String getConsignerName() {
        return consignerName;
    }

    public void setConsignerName(String consignerName) {
        this.consignerName = consignerName;
    }

    @Override
    public String toString() {
        return "MebAcc [id=" + super.id + ", account=" + account + ", pwd=" + pwd + ", accountType=" + accountType
                + ", statusFlag=" + statusFlag + ", regDatetime=" + regDatetime + "]";
    }

    public String getCheckFlagRemark() {
        return checkFlagRemark;
    }

    public void setCheckFlagRemark(String checkFlagRemark) {
        this.checkFlagRemark = checkFlagRemark;
    }

}